<template>
  <div>
    <v-text-field v-model="title" label="标题" required></v-text-field>
    <v-select :items="types" v-model="type" solo></v-select>
    <v-btn @click="submit">submit</v-btn>
  </div>
</template>

<script>
export default {
  data() {
    return {
      title: '',
      types: [
        { text: '动画', value: 'a' },
        { text: '漫画', value: 'b' },
        { text: '游戏', value: 'c' },
        { text: '小说', value: 'd' }
      ],
      type: 'a'
    }
  },
  methods: {
    submit() {
      this.$emit('setting', {
        name: 'Hitokoto',
        config: {
          msg: this.title,
          type: this.type
        },
        data: {}
      })
    }
  }
}
</script>

